<?php

// +----------------------------------------------------------------------
// | H1CMS © OpenSource CMS
// +----------------------------------------------------------------------
// | Copyright (c) 2014-2016 http://www.h1cms.com All rights reserved.
// | Copyright (c) 2014-2016 嘉兴领格信息技术有限公司，并保留所有权利。
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Allen <allen@lg4.cn>
// +----------------------------------------------------------------------


require __DIR__ . '/../autoload.php';

use Lg\View\View;
use h1cms\H1;
use Lg\Database\DB;

function indexAction() {
    $db_info = DB::getConnection()->info();
    H1::$app->screen->title = __('控制面板');
    return View::make('index', [
                'db_info' => $db_info
    ]);
}

function imgAction() {
    echo Lg\Image\Image::make(STORAGE_DIR . 'upload/dog.jpg')->response('jpg');
}

function testAction() {
    
}
